<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8"/>
    <meta http-equiv="Access-Control-Allow-Origin"/>
    <title>渲染片段</title>
</head>
<body  h-model="{user:{url:'http://localhost:8080/v/game/getUser'}}">

<p>
属性测试:<span  h-text="{user.username}">xxx1</span>
</p>
<p>
获取全局数据:<span  h-text="{ctx}">xxx1</span>
</p>
<script src="http://cdn.bootcss.com/zepto/1.1.6/zepto.js"></script>
<!--<script src="http://cdn.bootcss.com/jquery/1.11.2/jquery.min.js"></script>-->
<!--去掉下面两个js可以预览静态效果-->
<script src="../domTemplate.js"></script>
<script type="text/javascript">
    $(function () {
        $.domTemplate.init({data:{ctx:'http://172.0.0.1'}});
    });

</script>


</body>
</html>